An ever-increasing number of people who don't work at a large business or university want access to the Internet, and an equally ever-increasing number of Internet access providers are springing up to meet that need. Because individuals seldom have the level of connectivity enjoyed by those in business or education, they must make do with slower connections. Until recently, they've had to cope with clumsy Unix shell accounts as well. That clumsiness is avoidable now that SLIP (Serial Line Internet Protocol) and PPP (Point to Point Protocol) accounts have become widely available; more importantly, they provide access to some extremely cool software that I talk about in future chapters.
PPP provides an Internet connection for people who connect via modem. If you have a network, either Ethernet or LocalTalk, connected to the Internet, you don't need PPP. I talk about SLIP in more detail in chapter 19, "SLIP," so in this chapter I concentrate on PPP, mentioning SLIP only when the situation in question applies equally to SLIP as to PPP.
Note: Although PPP is generally used with normal phone lines and modems, if your provider and telephone company both offer ISDN (Integrated Services Digital Network) service, you can use PPP with ISDN and a terminal adapter like the Motorola BitSURFR in place of a modem to create a high speed Internet connection, often for not much more than a normal phone line would cost, if you're lucky.
The easiest way to understand PPP is to pretend that you don't have water service inside your house. Every time you want to take a shower, you must run a garden hose out to the water hookup outside, take your shower, and then reel the hose back in. That's exactly what PPP does -- it establishes a temporary, low-speed connection to the Internet. You must create that connection before you can run programs such as Anarchie and TurboGopher.
Note: Although most implementations of PPP allow you to launch a MacTCP-based program without connecting first (the PPP software sees what's up and then establishes the connection), I've found that auto connect features can be flaky. If you can use one, great, but if it doesn't work reliably, connect manually first.
What's the difference between PPP and SLIP, and should you care? The answer to the first part of the question seems to be that PPP is SLIP done right. Apparently, SLIP was literally designed on the back of an envelope and implemented in an afternoon. PPP, in contrast, was designed more carefully and is far more flexible, so that in theory it supports multiple protocols (such as AppleTalk and TCP/IP) at the same time and over the same connection. The capability to support multiple protocols is neat because you can use MacTCP programs at the same time as you are dialed into an AppleTalk server, much as you can do with Apple Remote Access now, but the reality is that not all of the Macintosh PPP implementations (like MacPPP) support anything besides TCP/IP.
Note: PPP and SLIP accounts are not identical. You cannot use a SLIP account with MacPPP, or a PPP account with InterSLIP.
As to whether or not you should care, my impression is that at the moment it doesn't make much difference. PPP may become the standard because Apple is working on supporting it more fully. Also, PPP has proven to be somewhat more reliable than SLIP in the past, although that may be related to the specific implementations of PPP and SLIP. In general, I believe that PPP is the way to go, if you can. That's why the ISKM Installer installs MacPPP by default, but also allows you to install InterSLIP should you only be able to get a SLIP account. Of course, if you simply cannot get a PPP account to work, there's nothing wrong with trying a SLIP account instead.
Now, does that mean that you should run out and switch an existing SLIP account over to PPP? No, if everything you want to do with your account works as you expect, definitely not. PPP and SLIP are functionally identical in that all, or almost all, of the MacTCP-based programs should work the same way with either SLIP or PPP accounts. I haven't seen significant performance differences between the two, although PPP occasionally feels a little more responsive in interactive use (as opposed to raw download speed when you're retrieving a file via FTP and nothing else). In addition, I've seen situations in which InterSLIP didn't work worth beans, but MacPPP worked instantly, and also situations in which InterSLIP was working perfectly but MacPPP never quite worked.
Hayden has licensed MacPPP and included it on the disk for your convenience. It was written by Larry Blunk of Merit Network, Inc., one of the companies that helped run the NSFNET. Commercial competition for MacPPP comes from InterPPP, a beefed-up version of PPP, marketed by InterCon. InterPPP's main claim to fame is that it supports AppleTalk over PPP, which is not true of MacPPP. There are several other less common implementations of PPP from Tribe and Pacer Software, but they reportedly use the same code as the version InterCon licensed and calls InterPPP.
Note: Although it's not yet available as I write this, Hyde Park Software is adding PPP support to MacSLIP (see chapter 19, "SLIP") so it will become a contender in the near future as well. The only change in MacSLIP's standard interface is a PPP Transport button and options to use PAP or CHAP, two authentication protocols for PPP.
I concentrate on MacPPP because the other PPP implementations, being commercial, come with printed documentation and support. In addition, MacPPP works extremely well for most people, and it is easy to configure, so it's the best choice for anyone starting out. If you discover that you need the added flexibility of something like InterPPP, you can check it out as well.
When it comes time for you to get a PPP account, you should check back in chapter 11, "Choosing a Connection," for information on how to pick an Internet access provider. Once you decide on a provider, you need certain information from that provider to configure MacPPP or InterPPP. For convenience, I list the most common pieces of information that you need in Table 18.1.
Table 18.1: PPP Information Item Question Phone number What number do I call to connect to the server? Login name What is my SLIP or PPP account login name? (This name can be different from your userid or machine name.) Password What password should I provide when logging in? Login Procedure What should I expect to receive from your host machine and how should my Mac respond when logging in?
You also can use the worksheet in the back of this book for recording all of this information. Although unusual, there are other variables that you may need to set in MacPPP, and if that's true, your Internet access provider will give you that information. The vast majority of them work with the default settings, luckily.
The free MacPPP, from Larry Blunk of Merit Network, is my dialup connection method of choice. This is partly because of its simple configuration and setup, and partly because there are a few programs that don't work with the Server-addressed SLIP accounts on my Internet access provider, Northwest Nexus, but that work fine with a Server-addressed PPP account. Because it generally works so well, I've included it on the disk as the default for those who want to work with one of the providers listed in appendix A, "Internet Starter Kit Providers."
Note: If you want to switch from SLIP to PPP, you must first switch your account to PPP with your provider. When that's done, throw out MacTCP, MacTCP DNR, MacTCP Prep, InterSLIP, and InterSLIP Control (if installed) and restart before installing MacPPP.
Installing MacPPP requires placing a control panel called Config PPP in your Control Panels folder, and an extension called PPP in your Extensions folder. If you drag them onto your closed System Folder, System 7 automatically places them in the proper folders.
Note: Once again, the ISKM Installer installs MacPPP properly for you -- I include these instructions so you know what's happened and can duplicate it with original files downloaded from the Internet.
After you've installed Config PPP and PPP, restart your Mac. Make sure that PPP is selected in the main MacTCP window, and that you use Server-addressing. PPP has the useful feature of being able to (at least in theory since this isn't a common setup), use Server-addressing even if you have a permanent IP address assigned to you. Being able to use Server-addressing with a static IP address ensures that you don't have to enter your IP address or Gateway Address into MacTCP, generally reducing the configuration work.
Note: It's possible to use the Manually-addressing option, but if you do that, you may have to configure the IPCP dialog (accessible within the Config PPP configuration dialog) with your permanent IP address in the Local column and your Gateway Address in the Remote column. The MacPPP documentation doesn't recommend this, and I was unable to test it. Consider yourself forewarned.
Open the Config PPP control panel. As you can see in figure 18.1, Config PPP has a vaguely clunky interface, but it is almost effortless to configure.
Figure 18.1: Config PPP control panel.
The Port Name pop-up menu enables you to choose the Modem port or Printer port (or any other ports registered with the Communications Toolbox); it is usually set to Modem port.
Note: If you use a PowerBook with an internal modem, the Port Name pop-up menu may confuse you. A few PowerBook modems, including the Apple Express Modem, the Global Village PowerPort/Mercury for the PowerBook 500-series, and Duos, are bus modems, and show up in the menu as Internal Modem. Other internal PowerBook modems are non-bus modems and use an internal connection to the Modem port. For these, choose Modem port. Mac AV users may also have a GeoPort option.
The Idle Timeout pop-up enables you to set a time of inactivity, from five to 120 minutes, after which MacPPP will close the connection. If you do anything during this time, the timer resets and MacPPP starts counting again. If your connection remains idle for the duration specified, MacPPP closes the connection. If you have the Quiet Mode checkbox checked, MacPPP does so without warning; if not, then at the end of the idle time period MacPPP presents you with a dialog that enables you to either ignore the warning and leave the PPP connection active, or close PPP.
I haven't used this feature much, because I simply connect when I want something and disconnect when I'm done. However, I see two tremendous uses for this feature. First, for those people who pay by the minute for their connections, having MacPPP hang up if the line is idle could save you a fair amount of money. Second, if you want to download a large file before you go to bed, simply set MacPPP to a relatively short timeout value and it will hang up when it's done downloading the file. Make sure Quiet Mode is checked if you want it to hang up without confirmation.
Note: Some people have experienced problems with MacPPP connecting seemingly randomly. Although most cases are caused by a program like Anarchie or TurboGopher asking for MacTCP services, it seems that on occasion MacTCP simply decides to do something and asks MacPPP to dial out. If you experience this, setting a short idle time in MacPPP keeps those unwanted connections as short as possible. And of course, if you shut off your modem, MacPPP won't be able to dial out at all.
It appears that MacPPP does a soft close in this idle timeout situation, which means that a MacTCP-based application can automatically re-open the connection by requesting MacTCP services. If MacPPP did a hard close, applications wouldn't be able to re-open the connection automatically; you would have to click the Open button to open a new connection.
Note: I can't predict how different MacTCP-based applications will behave if their connection disappears due to the line being idle for five or ten minutes. If you anticipate being in a situation where MacPPP might hang up automatically after an idle timeout, make sure to save your work in all other open applications. Some applications may even hang your Mac, so be careful.
The Echo Interval pop-up menu provides the opportunity to configure MacPPP to periodically query the line to see if your connection has dropped. If MacPPP receives no response after three successive requests, MacPPP assumes that the connection has gone dead. I've always left Echo Interval turned off, although if you have trouble with your connection dropping frequently, using it may make life easier. When MacPPP detects a dead connection, it pops up a dialog box with three buttons for Close PPP, Ignore, or Restart, which in this case means restarting the PPP connection, not the Macintosh. Of course, if your connection drops, you must at least quit open MacTCP applications before trying to do anything else. You may have to restart to clear things up appropriately if the open applications have become sufficiently confused by the loss of the connection.
Note: The Echo Interval feature continually sends packets to the server and waits for a response, but these packets don't count as traffic for the Idle Timeout feature.
The Terminal Window checkbox is one of MacPPP's most useful features. If you check it, MacPPP ignores the Phone number and Modem init fields in the Configure Server and Connect Script dialog boxes (I'll get to them in a minute). Instead, it makes you walk through the connection manually, starting with dialing the modem with an ATDT command.
Note: In some situations, MacPPP's terminal window doesn't echo what you type back to the screen, but the characters will be sent when you press Return.
You may never need to use MacPPP's terminal emulator, but if you have trouble logging on, it's much easier to have the terminal emulator built into MacPPP rather than be forced to use an external one (see figure 18.2).
Figure 18.2: MacPPP terminal window.
If you must use the terminal window, dial the modem manually, enter your username and password, and once you start seeing some gibberish characters that indicate the start of PPP data, click OK to start the PPP session.
Note: I strongly recommend that you use MacPPP's terminal window if you're having trouble getting connected because it often reveals problems on the provider's end (like they didn't set up a PPP account for you) and eliminates any mistakes you might have made in the connect script.
The two final checkboxes in the window are Hangup on Close and Quiet Mode. Hangup on Close, if checked, sends the Hayes +++ escape string and then an ATH to hang up the modem. My modem hangs up fine without this checkbox selected, but if yours doesn't, select it. The Quiet Mode checkbox prevents certain actions from requiring confirmation, most notably the Idle Timeout disconnect.
Once you've configured the main part of the Config PPP control panel, click the New button to create a new configuration. Name it, and it appears in the PPP Server pop-up menu. If you want to delete one, make sure it's showing in the menu and click the Delete button. After creating a new configuration, click the Config button to bring up the Configure Server dialog box (see figure 18.3).
Figure 18.3: MacPPP Configure Server dialog.
If you want to rename your server configuration, you can edit it in the PPP Server Name field. It makes absolutely no difference what you set the server name to -- it's only for your use. In the version of the PPP Preferences the ISKM Installer puts on your disk, I use the PPP Server Name field to identify different modems, for instance.
After you set the PPP Server Name, you can configure the basic modem variables. Set the Port Speed pop-up menu as high as it will work with your modem (my WorldBlazer doesn't like speeds over 19,200 bps by default), and always try to use a Port Speed faster than your modem, so it can take advantage of the modem's compression capabilities.
The Port Speed is the speed at which the Mac and the modem communicate, not the speed at which the two modems communicate (unless it happens to be slower than the fastest speed the modems have in common, at which point it forces the modems to communicate at that speed). Do not set the Port Speed menu to 14400 or 28800 even if you have a 14,400 bps or 28,800 bps modem. The reason is that some modems don't accept those as valid port speeds, and MacPPP won't talk to the modem properly.
Note: Port speed is reportedly irrelevant if you use a bus modem, since it doesn't use the modem port. I'd set it to 57600 if you have one of these modems.
Modem flow control, also sometimes called handshaking, is one of the most confusing topics in telecommunications on the Macintosh. The basic idea is that the flow of the incoming and outgoing packets must be organized and controlled or else you experience the packet equivalent of traffic jams and accidents. For a modem to do handshaking in hardware, you need a special cable (luckily, one that comes with most fast modems sold for Macs, although every now and then someone has trouble because you can't use high speeds on modern modems without one). All of the various options we have discussed are forms of hardware flow control or hardware handshaking. PPP can, in theory, use software flow control, also called XON/XOFF, which doesn't require a special cable, but I've never seen anyone try. Usually, there's no point.
The Flow Control pop-up menu has options for None, CTS only, RTS (DTR) only, and CTS & RTS (DTR). I recommend that you try setting CTS & RTS (DTR) as the first try. The problem with the CTS & RTS (DTR) setting is that you may experience random hangups when lots of data is coming in unless your modem init string includes &D0, or, if your init string uses &D2, it is also properly configured to ignore short periods of DTR going low (check your modem manual for the S25 S-register setting and try setting it to 50 in the modem init string). If that's true, try dropping down to CTS only. I ran into some of the hangups, and haven't had any trouble at all since I switched to CTS only.
Note: Internal PowerBook bus modems can have the Flow Control pop-up menu set to None; all other modems must use some sort of flow control.
Tone Dial versus Pulse Dial should be obvious based on your telephone. Tone dialing is far more prevalent these days. The phone number field should be self-evident, although you may have to add special prefixes to get through a company or hotel phone system. Adding the prefix of either 8 or 9 and a comma is a common solution (the comma ensures a short pause after sending the 8 or the 9 and before dialing the rest of the phone number).
Note: If you must enter a lot of digits in the phone number field to account for a calling card number, you may have to eliminate all the dashes, which aren't necessary and take up space in the field. I forget the maximum number of digits it can take, but I ran into it once when using a calling card number.
Next we come to the Modem Init field. Modem initialization strings have been an unending source of headaches for Internet users configuring SLIP and PPP accounts. My recommendation is to start with the factory default configuration for your modem (usually AT&F, AT&F1, or AT&F2, although the numbers change depending on the modem).
Note: If you use the ISKM Installer to install MacPPP, you get a PPP Preferences file that contains a number of likely (but untested) modem strings for many modem types. In addition, even more modem strings are located in a file called Modem Strings in the MacPPP 2.0.1 folder in your ISKM3 Folder.
I should make one uncommon but important point. Make sure that XON/XOFF, or software flow control, is turned off. On at least one modem, the Telebit QBlazer, MacPPP fails badly if XON/XOFF is active, and the MacPPP documentation notes that software flow control should be turned off as well, so I'm assuming that XON/XOFF is Public Enemy Number One with PPP (or SLIP) accounts.
Note: You may wonder what the X2 is doing in my initialization string. I discovered that my Telebit WorldBlazer doesn't return the BUSY code in the default X1 setting, and if the modem doesn't return that BUSY code, MacPPP has no way to know that the line is busy and it should redial (which it does automatically). Other modems may have a similar problem.
Finally, the Modem connect timeout field offers you a chance to increase the amount of time MacPPP will wait for the connection to occur. If it takes MacPPP a long time to negotiate your connection, you may need to increase this value.
As more alert readers will have noticed, I haven't yet mentioned where you enter your userid and password. There are two possibilities here, depending on what the PPP server on your host machine supports. If you're lucky, you can use PPP's Password Authentication Protocol (PAP) to negotiate your connection. If your server doesn't support that (I have no idea how common it is), you instead must use a connect script. First, the Authentication dialog (see figure 18.4).
Figure 18.4: MacPPP Authentication dialog.
As you can see, all you do here is enter your Authentication ID and Password into the appropriate fields. The Auth. ID field holds your userid and the Password field holds your PPP password, appropriately hidden so others can't see it. If you're really paranoid about your password, you can leave that field blank and MacPPP will prompt you to enter it every time you connect.
Click OK to save your changes and return to the Configure Server dialog. If you use the Authentication dialog, you need not enter anything in the Connect Script dialog, and in fact, you're best off deleting anything that might be in there. In testing with the servers at Northwest Nexus, I found that MacPPP would try to run through the Connect Script information first, and if that failed, it would then fall back to the information from the Authentication dialog. If, however, the Connect Script dialog was empty, MacPPP sent the authentication information without worrying about looking for the login and password prompts. I don't know if this is the standard process for servers or not.
Note: If you leave the Connect Script blank or configure it incorrectly, and leave the Authentication dialog empty, MacPPP prompts you for your userid and password, just as you would have entered them in the Authentication dialog.
If using the Authentication method of logging in to your PPP server machine doesn't work, you must instead use the Connect Script dialog to script your way in. It's still pretty easy (see figure 18.5).
Figure 18.5: MacPPP Connect Script dialog.
Basically, all you do in the Connect Script dialog is replicate the process of logging in to your host manually (and the terminal window can be helpful in figuring out the connect script). You click an Out button to indicate that MacPPP should send the contents of the field to the left (and a carriage return if the checkbox is selected for that line), and you click a Wait button to indicate that MacPPP should wait for the string specified in the field to appear before moving on to the next line.
Note: If you're unlucky, connecting to your PPP server will require more than the eight fields MacPPP provides here. In that case, if your server doesn't support authenticated logins as discussed previously (which is likely, if it requires more than four send/expect interactions), your only option may be to use the commercial InterPPP. Actually, that's not entirely true, since you can do some funky scripting within MacPPP by using special codes like \t (which drops you into the terminal window at that point in the script), \r (which sends a Return to the host), and \d (which forces a short delay). The trick when creating such a hacked script is to use delays instead of the Wait buttons, thus enabling you to cram more functional script lines into the same space.
My connect script in figure 18.5 says, when translated: "Send a carriage return as soon as you're connected. Then wait for the string 'ogin:' to appear, and once you've seen it, send the username 'Ptidbits' and a carriage return. Wait for the string 'word:' to appear, and then send the password and a carriage return." Once you're done scripting here, click OK to save your script.
Note: The words "login" and "password" often have their first letter or letters removed in scripts like this, because you never know whether or not the first letter will be capitalized.
Meanwhile, back in the Configure Server dialog, you've probably been wondering what's inside the LCP Options dialog and the IPCP Options dialog. You really don't want to know, and I'm not going to show you. Suffice it to say that I'll be very surprised if you know what to do with the options in there. I certainly don't, and the MacPPP documentation says that no normal user should ever have to change any of those settings.
Well, that's it for configuring MacPPP. It's quite easy, and in fact, it may be the easiest method of connecting to the Internet.
Once it's configured, using MacPPP is a piece of cake. Like InterSLIP, it works in both manual and automatic modes, so you can either click the Open button in Config PPP or you can merely open a MacTCP-based program that opens MacTCP, at which point MacPPP connects automatically. I've found MacPPP's auto-connect feature to be fairly reliable, although not absolutely guaranteed. It seems that some applications don't quite play by the rules, and those applications won't work in auto-connect mode.
Note: MacPPP's auto-connect feature only works on the second or subsequent connections after you restart your Mac if you use Soft Close to close your connection. If you use Hard Close, MacPPP cannot auto-connect. Nonetheless, there are some cases of MacPPP dialing for apparently no reason that are eliminated with Hard Close, so that's what I always use.
Once you click the Open button or have MacPPP connect automatically, you see some dialogs indicating that MacPPP is dialing, logging in, establishing the PPP link, and checking for the network. After those dialogs, the little faces under the Open button will become happy faces and the connection will be complete.
Note: Be careful of the auto-connect mode -- if you do something like put TurboGopher in your Startup Items folder, it will launch on every startup and make MacPPP establish a connection to the Internet. You're unlikely to do that with TurboGopher, but certain control panels or extensions also can activate the auto-connect feature, which can be a pain.
Once you've established a PPP connection with MacPPP, you can run any of the MacTCP-based applications and do whatever you want. If you click the Stats button in Config PPP, MacPPP presents you with a relatively meaningless dialog full of technical statistics. I've never bothered with them and I haven't talked to anyone who has, either.
When you're done with your work and want to close your connection, first quit all of your MacTCP-based applications. Some of them dislike having the connection disappear from under their little electronic feet. To pull the plug on the PPP connection, you can do one of two things, depending on how you use MacPPP. First, you can click the Hard Close button, which hangs up the connection and "locks" MacPPP so that the only way to establish a new connection is to click the Open button. This prevents any applications from forcing MacPPP to open the connection automatically while, say, you're not present. Second, if it doesn't bother you to possibly have applications dialing your phone behind your back, you can click the Soft Close button to close a connection. That leaves open the auto-connect feature for the rest of that session, so launching an application makes MacPPP establish a new connection.
My only real quibble with MacPPP is that I don't think much of the aesthetics of the interface (hey, call me an interface snob -- I don't mind). Actually, if I wanted to quibble some more, MacPPP could use some updated documentation, and it would be very nice if it could dial and redial in the background.
Overall, though, I find MacPPP to be an excellent program and perhaps the simplest way of establishing a connection to the Internet (assuming that the PPP server in question supports authentication).
Larry Blunk and Merit Network deserve kudos for making such a fine program available to the Macintosh Internet community for free. However, I should note that they cannot support MacPPP, so if you have problems or questions about it, you should ask on a mailing list like the Apple Internet Users mailing list (send a message containing the command info apple-internet-users to listproc@abs.apple.com for information on how to subscribe) or in a newsgroup like comp.sys.mac.comm. You can retrieve the latest version of MacPPP on the Internet from either of the following:
ftp://ftp.tidbits.com/pub/tidbits/tisk/tcp/